<template>
	<view class="mykehu p20">
		<myNav>
			<view slot="left" @click="back"><uni-icons type="closeempty" color="#fff"></uni-icons></view>
			<view class="center">户型图</view>
		</myNav>
		<p class="name">房间名称: 测试一号楼盘-测试一期-A区-七单元-11栋-2-3202</p>
		<image src="../../static/all/baobei/icon4-1.jpg" @click="watch" mode=""></image>
	</view>
</template>

<script>
import { mapMutations } from 'vuex';
import darkCalendar from '@/components/dark-calendar/dark-calendar';
import myNav from '../../components/mynav/mynav.vue';
import { searchedVistor } from '@/api/index.js';
import { MyShow } from '@/util/my.js';
export default {
	components: { myNav, darkCalendar },
	data() {
		return {
			para: ''
		};
	},
	methods: {
		back() {
			uni.switchTab({
				url: '../my/my'
			});
		},
		async searchedVistor() {
			//去请求接口
			//  todo 字段自己填充吧
			// console.log('去请求接口');
			try {
				let reslut = await searchedVistor({
					para: this.para
				});
				//成功
				new MyShow('需要渲染的字段').tixing();
			} catch (e) {
				//TODO handle the exception
				new MyShow('需要渲染的字段').tixing();
			}
		},
		gotoinfo(val) {
			uni.navigateTo({
				url: './p11'
			});
		},
		goto(val) {
			uni.navigateTo({
				// url: './p21?id=' + val.id
			});
		},
		watch(){
			uni.previewImage({
				urls:["https://lupic.cdn.bcebos.com/20191203/3016020261_14.jpg"],
				count:1,
				success(res) {
					console.log(res,1)
				},
				fail(res) {
					console.log(res,2)
				}
			})
		}
	}
};
</script>

<style lang="scss">
@import './main.scss';
.name{
	font-size: 14px;
	    font-weight: 400;
	    font-style: normal;
}
</style>
